/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package mapdbtest;

import java.io.Serializable;
import java.time.LocalDate;
import javafx.beans.property.IntegerProperty;
import javafx.beans.property.ObjectProperty;
import javafx.beans.property.SimpleIntegerProperty;
import javafx.beans.property.SimpleObjectProperty;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.StringProperty;

/**
 *
 * @author Arttu
 */
public class ObservableNote {
    
    private final IntegerProperty id = new SimpleIntegerProperty();
    private final StringProperty note = new SimpleStringProperty();
    private final ObjectProperty<LocalDate> created = new SimpleObjectProperty<>();
    private final StringProperty heading = new SimpleStringProperty();

    public ObservableNote() {
        
    }
    
    public String getHeading() {
        return heading.get();
    }

    public void setHeading(String value) {
        heading.set(value);
    }

    public StringProperty headingProperty() {
        return heading;
    }

    public LocalDate getCreated() {
        return created.get();
    }

    public void setCreated(LocalDate value) {
        created.set(value);
    }

    public ObjectProperty createdProperty() {
        return created;
    }

    public String getNote() {
        return note.get();
    }

    public void setNote(String value) {
        note.set(value);
    }

    public StringProperty noteProperty() {
        return note;
    }

    public int getId() {
        return id.get();
    }

    public void setId(int value) {
        id.set(value);
    }

    public IntegerProperty idProperty() {
        return id;
    }

    @Override
    public String toString() {
        return getId() + ": " + getHeading();
    }

    
}
